home *** CD-ROM | disk | FTP | other *** search
/ PsL Monthly 1993 December / PSL Monthly Shareware CD-ROM (December 1993).iso / prgmming / dos / c / thandlr.exe / THANDLER.DOC < prev    next >
Encoding:
Text File  |  1993-02-21  |  11.3 KB  |  301 lines

  1.  
  2.      THandler Version 1.01
  3.      (C) Copyright 1992, 1993 Michael Newton and Comsoft Software
  4.      All rights reserved.
  5.  
  6.      The THandler C++ library was created with Borland C++ version 3.1 and
  7.      Borland's Turbo Vision version 1.01.
  8.  
  9.      Michael Newton
  10.      Comsoft Software
  11.      32939 Watson Rd.
  12.      Scappoose OR 97056 USA
  13.  
  14.      Voice           (503) 543-3720
  15.      Voice           (206) 481-7840
  16.      CompuServe      70402,531
  17.      Internet        70402.531@compuserve.com
  18. --------------------------------------------------------------------------------
  19.  
  20. File list
  21.  
  22. Filename        Description
  23. --------------------------------------------------------------------------------
  24. THANDLER.LIB    Large model C++ library file
  25. THANDLER.HPP    Header file for the THandler class
  26. THANDLER.DOC    This file
  27. TDEMO.CPP       C++ source file for the THandler demo program
  28. ORDER.DOC       Order form
  29.  
  30. --------------------------------------------------------------------------------
  31. What is it?
  32. -----------
  33.  
  34.    THandler is an interrupt 24H (Hardware error) handler for your Turbo Vision
  35. applications. It replaces Turbo Vision's own TSystemError class.
  36.  
  37.  
  38.  
  39.                                     Page 1
  40.  
  41.                              THandler Version 1.01
  42. --------------------------------------------------------------------------------
  43. How do I use it?
  44. ----------------
  45.  
  46.    THandler class summary THANDLER.HPP
  47.  
  48.    THandler
  49.  
  50.    See the source code in tdemo.cpp for a demonstration of using THandler.
  51. Basically, all that's needed is to create an instance of THandler in your
  52. application prior to any code which might need the handler. The constructor
  53. installs the interrupt service routine. When the handler is no longer needed
  54. it should be destroyed.
  55.  
  56. NOTE:
  57.    THandler uses the interrupt keyword, therefor the Stack warning checkbox
  58. should be unchecked (off) and the Register Variables option should be set to
  59. None. You cannot compile a program that uses THandler with Test Stack Overflow
  60. turned on and get an executable file that operates correctly.
  61.  
  62.    THandler replaces Turbo Vision's TSystemError class. It provides system error
  63. handlers and associated services.
  64.  
  65. Most of its members are private and will not be of direct interest in normal
  66. Turbo Vision applications.
  67.  
  68. Constructor and Destructor:
  69. ---------------------------
  70.  
  71. THandler(Boolean isSound = True);
  72.  
  73.    Creates a THandler object and installs the system error handler. Suspends
  74. TSystemError by calling TSystemError::suspend().
  75.    The optional 'isSound' parameter controlls Thandler's use of sound. A value
  76. of 'True', or (1)' turns sound on, while a value of 'False', or (0), turns
  77. sound off. The default is True.
  78.  
  79. ~THandler();
  80.    Removes the system error handler and re-installs TSystemError by calling
  81. TSystemError::resume().
  82.  
  83.  
  84. Member Functions:
  85. -----------------
  86.  
  87. void resume();
  88.  
  89.    Suspends TSystemError by calling TSystemError::suspend and re-installs
  90. THandler's system error handler.
  91.  
  92.  
  93. void suspend();
  94.  
  95.    Removes THandler's system error handler and re-installs TSystemError's error
  96. handler by calling TSystemError::resume().
  97.  
  98.                                     Page 2
  99.  
  100.                              THandler Version 1.01
  101. --------------------------------------------------------------------------------
  102.  
  103. Member Functions:  (cont.)
  104. -----------------
  105.  
  106. void setSound(Boolean isSound);
  107.  
  108.    Sets THandler's use of sound by assigning the value of 'isSound' to the
  109. static variable 'sounds'. If value of 'isSound' is 'True', Thandler will sound a
  110. tone when an error occurs. A value of 'False' turns sound off.
  111.  
  112.  
  113. Boolean getSound();
  114.  
  115.    Returns the current value of THandler's 'sounds' variable.
  116.  
  117. --------------------------------------------------------------------------------
  118. TDemo
  119. -----
  120.  
  121.    To compile TDEMO.EXE from the BC++ IDE, create a project file which includes
  122. THANDLER.LIB AND TDEMO.CPP, hit "build all" or "run", and viola!
  123.    TDEMO.EXE demonstrates THandler by allowing the user to select various system
  124. devices to access. When the demo program attempts to access a device that is not
  125. ready, such as a floppy drive with no disk in the drive, interrupt 24H is
  126. generated and program flow is directed to THandler's newInt24 function. This
  127. function executes an error dialog box which shows the user which device caused
  128. the error, and what type of error occured. The error dialog box has buttons for
  129. Abort, Retry, Ignore, and Fail. Depending on the type of error, some of these
  130. buttons may be disabled.
  131.  
  132. --------------------------------------------------------------------------------
  133. Shareware message
  134. -----------------
  135.  
  136.    THandler is distributed as "shareware" in C++ library form. Try it, use it,
  137. and pass it on to your friends (in the original, unaltered distribution
  138. archive). THandler is NOT public domain or free software. If you use it you must
  139. pay for it. Registration is required if you use this library, or source code, at
  140. work (i.e. in a business or institutional setting).
  141.  
  142.    Our livelihood depends on the honesty and integrity of THandler users. Your
  143. registration will help pay the programmer for his hard work, and encourage
  144. continued support and development of THandler and other quality programming
  145. utilities. In addition, you will be showing others that you support the
  146. shareware concept.
  147.  
  148.                                     Page 3
  149.  
  150.                              THandler Version 1.01
  151. --------------------------------------------------------------------------------
  152.  
  153. Pricing
  154. -------
  155.  
  156.    Single copies of the THandler library are $20 US plus $3 shipping and
  157. handling. If you would like THandler on a 3.5" disk, add $2.
  158.  
  159.    Fully commented C++ source code for THandler is also available for $45 US
  160. plus $3 shipping and handling. If you would like the source code on a 3.5" disk,
  161. add $2.
  162.  
  163.    Orders from outside the USA are $3 extra.
  164.  
  165. --------------------------------------------------------------------------------
  166. Ordering
  167. --------
  168.  
  169.    To order, print the file "ORDER.DOC", fill it out and mail it, along with
  170. your check or money order, to the address below.
  171.  
  172.    You may also write the following information on a piece of paper and mail it,
  173. along with your check or money order, to the address below.
  174.  
  175. Your name
  176. Your address
  177. Your phone number (optional)
  178. The disk size you require. (5.25" or 3.5")
  179. The number of copies you wish to purchase.
  180. Please specify either THandler library or THandler library with source.
  181.  
  182.    Please send payment, in the form of a check or money order, to...
  183.  
  184.    Michael Newton
  185.    32939 Watson Rd.
  186.    Scappoose OR 97056 USA
  187.  
  188. --------------------------------------------------------------------------------
  189. Disclaimer!
  190. -----------
  191.  
  192.    You use this library, and/or source, code (just like any other) at your own
  193. risk, so be careful. Read the documentation, follow instructions, and make
  194. backups. We can't guarantee that this code will work with every possible
  195. combination of hardware and software out there in the real world (or that it
  196. will work at all, for that matter). While we have done our best to produce
  197. well-written, bug-free code, oversights and omissions can happen.
  198.  
  199.                                     Page 4
  200.  
  201.                              THandler Version 1.01
  202. --------------------------------------------------------------------------------
  203.  
  204. Disclaimer! (cont.)
  205. -----------
  206.  
  207.    No software is completely safe from bugs, glitches, and "stupid user tricks".
  208. We cannot be responsible for any damages which might occur as a result of using
  209. THandler. We cannot guarantee it will be "safe" or "harmless" in all possible
  210. applications, and any lost time, data, hardware, or software you incur as a
  211. result of using THandler is your responsibility alone. If this disclaimer isn't
  212. good enough for you, don't use THandler.
  213.  
  214. --------------------------------------------------------------------------------
  215. Acknowledgements
  216. ----------------
  217.  
  218.    We mention other people's products in this document, and would like to give
  219. credit where credit is due.
  220.  
  221.    - Turbo Vision is a trademark of Borland International.
  222.    - Borland C++ is a trademark of Borland International.
  223.    - MS-DOS is a trademark of Microsoft Corporation.
  224.  
  225. --------------------------------------------------------------------------------
  226. Contacting the Authors
  227. ----------------------
  228.  
  229.    Michael 'Mick' Newton is responsible for the development of THandler as well
  230. as this fine documentation.
  231.    We always like to hear from our users, whether you've already registered
  232. THandler or are still evaluating it. For urgent technical support, or to give
  233. the programmer a piece of your mind, call us at...
  234.  
  235.    Voice          (503) 543-3720 Oregon
  236.    Voice          (206) 481-7840 Washington
  237.  
  238. or send email to...
  239.  
  240.    CompuServe      70402,531
  241.    Internet        70402.531@compuserve.com
  242. --------------------------------------------------------------------------------
  243. Revision history
  244. ----------------
  245.  
  246. 05-21-92   First release.
  247.  
  248. 06-02-92   Fixed bug where selecting 'Abort' from the error handler dialog
  249.            box would cause a system lock-up.
  250.  
  251. 06-27-92   Recompiled with Borland BC++ 3.1 and updated Turbo Vision.
  252.            Fixed 'superflous & with function' warnings.
  253.  
  254.                                     Page 5
  255.  
  256.  
  257.          ----------------end-of-author's-documentation---------------
  258.  
  259.                          Software Library Information:
  260.  
  261.                     This disk copy provided as a service of
  262.  
  263.                            Public (software) Library
  264.  
  265.          We are not the authors of this program, nor are we associated
  266.          with the author in any way other than as a distributor of the
  267.          program in accordance with the author's terms of distribution.
  268.  
  269.          Please direct shareware payments and specific questions about
  270.          this program to the author of the program, whose name appears
  271.          elsewhere in  this documentation. If you have trouble getting
  272.          in touch with the author,  we will do whatever we can to help
  273.          you with your questions. All programs have been tested and do
  274.          run.  To report problems,  please use the form that is in the
  275.          file PROBLEM.DOC on many of our disks or in other written for-
  276.          mat with screen printouts, if possible.  PsL cannot debug pro-
  277.          programs over the telephone, though we can answer questions.
  278.  
  279.          Disks in the PsL are updated  monthly,  so if you did not get
  280.          this disk directly from the PsL, you should be aware that the
  281.          files in this set may no longer be the current versions. Also,
  282.          if you got this disk from another vendor and are having prob-
  283.          lems,  be aware that  some files may have become corrupted or
  284.          lost by that vendor. Get a current, working disk from PsL.
  285.  
  286.          For a copy of the latest monthly software library newsletter
  287.          and a list of the 4,000+ disks in the library, call or write
  288.  
  289.                            Public (software) Library
  290.                                P.O.Box 35705 - F
  291.                             Houston, TX 77235-5705
  292.  
  293.                                 1-800-2424-PSL
  294.                              MC/Visa/AmEx/Discover
  295.  
  296.                           Outside of U.S. or in Texas
  297.                           or for general information,
  298.                               Call 1-713-524-6394
  299.  
  300.  
  301.